/**
 * Created by Baggio on 2018-1-5.
 */
$(function () {

});

/*用户-启用*/
function modifyUser(obj,id,status) {

    var postData = {tid: id, userType: status};
    console.log(postData);
    $.ajax({
        type: "post",
        url: '/admin/customer/modifyCustomer.html',
        data: postData,
        success: function (data) {
            var data = JSON.parse(data);
            if (data.code != 1) {
                console.log(data.msg);
                layer.msg(data.msg, {icon: 5, time: 1000});
                return;
            }

            layer.msg('已启用!', {icon: 6, time: 1000});
            location.reload();
        }
    });
}
    /* 导出Excel */
    function exportExcel() {
        var postData = $("#searchForm").formSerialize();
        window.location.href="/admin/customer/getCustomerListForExcel.html?"+ postData;
    }